package com.jm.framework.common.exception;

/**
 * tide
 * <p>
 * 业务异常
 * <p>
 * author: jiangjianmin
 * <p>
 * create: 2024-08-22 14:07
 **/
public class BizException extends RuntimeException {
    private final String code;
    private final String msg;



    public BizException(String code, String message) {
        super(code + message);
        this.code = code;
        this.msg = message;
    }

    public BizException(String message) {
        super(message);
        this.code = BaseResultCodeEnum.BIZ_ERROR.getCode();
        this.msg = message;
    }


    public String getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }
}
